import { ref, type Ref, nextTick } from 'vue'
const scroll = ref({
    x: 1000,
    y: 0
})
export function useTableScroll(className: string): Ref<{ x: number, y: number }> {
    nextTick(() => {
        const topHeight = 64
        const dom = document.getElementsByClassName(className)[0] as HTMLElement
        scroll.value.y = innerHeight - topHeight - dom.offsetHeight - 180
    })
    return scroll
}

